package org.simplecrm.repository.user;

import org.simplecrm.domain.user.User;

/**
 * Defines an interface for obtaining and changing data of DB
 * from table "security_user".
 */
public interface UserDAO {

    static final String U_ID_FIELD = "id";
    static final String U_USERGROUP_FIELD = "usergroupId";
    static final String U_LOGIN_FIELD = "login";
    static final String U_PASSWORD_FIELD = "password";

    /**
     * Is used for obtaining user from DB for security issues.
     *
     * @param username username
     * @return
     */
    User getUserByName(String username);

}